package com.chinaunicom.bigcustomer.service.impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.chinaunicom.bigcustomer.dao.GradeRuleMapper;
import com.chinaunicom.bigcustomer.dto.GradeRuleDto;
import com.chinaunicom.bigcustomer.model.GradeRule;
import com.chinaunicom.bigcustomer.service.IGradeRuleService;
@Service
public class GradeRuleServiceImpl implements IGradeRuleService {

	@Resource
	private GradeRuleMapper dao;
	@Override
	public int deleteByPrimaryKey(Integer nRuleno) {
		// TODO Auto-generated method stub
		return dao.deleteByPrimaryKey(nRuleno);
	}

	@Override
	public int insert(GradeRuleDto dto) {
		// TODO Auto-generated method stub
		return dao.insert(dto);
	}

	@Override
	public int insertSelective(GradeRule record) {
		// TODO Auto-generated method stub
		return dao.insertSelective(record);
	}

	@Override
	public GradeRuleDto selectByPrimaryKey(Integer nRuleno) {
		// TODO Auto-generated method stub
		return dao.selectByPrimaryKey(nRuleno);
	}

	@Override
	public int updateByPrimaryKeySelective(GradeRule record) {
		// TODO Auto-generated method stub
		return dao.updateByPrimaryKey(record);
	}

	@Override
	public int updateByPrimaryKey(int id) {
		// TODO Auto-generated method stub
		return dao.updateByPrimaryKeySelective(id);
	}

	@Override
	public List<GradeRuleDto> query(GradeRuleDto gradeRule) {
		// TODO Auto-generated method stub
		return dao.query(gradeRule);
	}

	@Override
	public List<GradeRuleDto> queryByBrand(String vBrandname) {
		// TODO Auto-generated method stub
		return dao.queryByBrand(vBrandname);
	}

	@Override
	public List<GradeRuleDto> queryByGrade(String vGrade) {
		// TODO Auto-generated method stub
		return dao.queryByGrade(vGrade);
	}

	@Override
	public List<GradeRuleDto> queryByName(GradeRuleDto dto) {
		// TODO Auto-generated method stub
		return dao.queryByName(dto);
	}

	@Override
	public int lockRuleByPrimaryKey(int id) {
		// TODO Auto-generated method stub
		return dao.lockRuleByPrimaryKey(id);
	}

	@Override
	public int unlockRuleByPrimaryKey(int id) {
		// TODO Auto-generated method stub
		return dao.unlockRuleByPrimaryKey(id);
	}

	@Override
	public int updateById(GradeRuleDto dto) {
		// TODO Auto-generated method stub
		return dao.updateById(dto);
	}

}
